package com.xnfh.equipment.adapter

import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseDataBindingHolder
import com.xnfh.common.bean.WarningItem
import com.xnfh.equipment.R
import com.xnfh.equipment.databinding.ItemSystemLogLayoutBinding

/**
 * @Description:
 * @Author: ziheng
 * @CreateDate: 2023/12/27 15:12
 * @UpdateUser: ziheng
 * @UpdateDate: 2023/12/27 15:12
 * @UpdateRemark: 更新说明
 */
class SystemLogAdapter: BaseQuickAdapter<WarningItem,BaseDataBindingHolder<ItemSystemLogLayoutBinding>>(
    R.layout.item_system_log_layout) {
    override fun convert(
        holder: BaseDataBindingHolder<ItemSystemLogLayoutBinding>,
        item: WarningItem
    ) {
        holder.setText(R.id.item_system_name,item.Logtxt)
        holder.setText(R.id.item_system_time,context.getString(R.string.time_mao) +item.Logtime.replace("T"," ").replace("Z",""))
    }
}